﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<Domain.MainModule.Entities.Customer>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    Client Details
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="SubHeaderContent" runat="server">
    <%: Html.DisplayForModel("CustomerBrief") %>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <% if (Model != null)
       { %>
    <%: Html.DisplayForModel() %>
    <% }
       else
       { %>
    No existe el cliente solicitado.
    <% } %>
    <div class="container-button" style="text-align:right">
    <a href="<%= Request.UrlReferrer %>">Back</a>
    <a href="<%: Url.Action("Edit", (object) new { customerId = Model.UserId }) %>">Edit</a>
    <a href="#" onclick="document.Delete.submit();">Delete</a>                
    <% using (Html.BeginForm("Delete", "Customer", new { customerId = Model.UserId }, FormMethod.Post, new { name = "Delete" }))
        { %>
         <%: Html.HttpMethodOverride(HttpVerbs.Delete) %>
    <%  } %>
<%--        <ul>
            <li><a href="<%= Request.UrlReferrer %>">
                <img src="<%: Url.Content("~/Content/Images/exit.png") %>" alt="Back" /></a></li>
            <li><a href="<%: Url.Action("Edit", (object) new { customerId = Model.UserId }) %>">
                <img src="<%: Url.Content("~/Content/Images/edit.png") %>" alt="Edit" /></a>
            </li>
            <li><a href="#" onclick="document.Delete.submit();">
                <img src="<%: Url.Content("~/Content/Images/delete.png") %>" alt="Delete" /></a>
                <% using (Html.BeginForm("Delete", "Customer", new { customerId = Model.UserId }, FormMethod.Post, new { name = "Delete" }))
                   { %>
                <%: Html.HttpMethodOverride(HttpVerbs.Delete) %>
            </li>
        </ul>
--%>    
    </div>
 <%--  <% } %>--%>
<table>
<tr><td><%: Html.DisplayForModel("Addresses")%></td><td><%: Html.DisplayForModel("VirtualAccounts")%></td></tr>
<tr><td><%: Html.DisplayForModel("Phones")%></td><td><%: Html.DisplayForModel("Identities")%></td></tr>
<tr><td><%: Html.DisplayForModel("CreditCards")%></td><td></td></tr>
</table>
</asp:Content>
